﻿@{
    ViewBag.Title = "Search";
    NRemedy.MVC.UI.NRemedyGrid<NRemedy.WS_Incident> IncidentList = new NRemedyGrid<NRemedy.WS_Incident>(
        new { style = "height:500px", id = "datagrid_incident" },
        new { pagination = true, fitColumns = true, singleSelect = true },
        null
        )
    .Column(p => p.RequestID, "ID", null, new { hidden = true, width = 50 })
    .Column(p => p.IncidentNumber, "事件号", null, new { sortable = true, width = 100 })
    .Column(p => p.Subject, "主题", null, new { width = 400 })
    .Column(p => p.Priority, "优先级", null, new { sortable = true, width = 30 })
    .Column(p => p.IncidentStatus, "状态", null, new { sortable = true, width = 50 })
    .Column(p => p.OwnerTeam, "负责团队", null, new { sortable = true, width = 150 })
    .Column(p => p.Owner, "处理人员", null, new { sortable = true, width = 50 })
    .Column(p => p.CreatedDateTime, "创建时间", null, new { sortable = true, width = 150 })
    .Qulification(ViewBag.Q)
    ;
    RouteValueDictionary detail = new RouteValueDictionary();
    detail.Add(NRemedyUIExtension.FormModelKey, "Detail");
}

<h2>Search</h2>
<script type="text/javascript">
    $(function () {
        $('#datagrid_incident').datagrid({
            onDblClickRow: function (rowIndex, rowData) {
                window.open('@Url.Action("Form", detail)' + '/' + rowData.f536870922);
            }
        });
    });
    </script>
@IncidentList.GetHtml()


